package org.obm.delivery.cassandra.impl;

import me.prettyprint.cassandra.service.Keyspace;

import org.obm.bigg.model.Messages;
import org.obm.cassandra.client.CassCommand;
import org.obm.cassandra.client.CassHelper;

public class WriteBUMCommand implements CassCommand {

	private BlownUpMessage bum;

	public WriteBUMCommand(BlownUpMessage bum) {
		this.bum = bum;
	}

	@Override
	public void run(Keyspace ks) throws Exception {
		CassHelper.insert(ks, Messages.CF, bum.getMessagesKey(), bum
				.getMessagesInfo());
	}

}
